package org.pan.domain.db;

import org.pan.domain.DomainObject;

import javax.persistence.*;
import java.util.List;
import java.util.Set;

/**
 * 系统角色
 * Created by Administrator on 2015/11/7.
 */
@Entity
public class SystemRole extends DomainObject {
    @Column
    private String roleName;

    @Column
    private String roleDescribe;

    @ManyToMany(mappedBy = "systemRoleSet")
    private Set<SystemMenu> systemMenuSet;

    @ManyToMany(mappedBy = "systemRoleList")
    private List<SystemAccount> systemAccountList;

    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName;
    }

    public String getRoleDescribe() {
        return roleDescribe;
    }

    public void setRoleDescribe(String roleDescribe) {
        this.roleDescribe = roleDescribe;
    }

    public Set<SystemMenu> getSystemMenuSet() {
        return systemMenuSet;
    }

    public void setSystemMenuSet(Set<SystemMenu> hasMenus) {
        this.systemMenuSet = hasMenus;
    }

    public List<SystemAccount> getSystemAccountList() {
        return systemAccountList;
    }

    public void setSystemAccountList(List<SystemAccount> systemAccountList) {
        this.systemAccountList = systemAccountList;
    }
}
